package controller.anneeEtude
{
	import model.proxy.AnneeEtudeProxy; 
	import model.AnneeUniversitaire;
	import model.Formation;
	import org.puremvc.as3.interfaces.INotification; 
	import org.puremvc.as3.patterns.command.SimpleCommand;
	 
	public class ObtenirListeEnseignantsEtudeCommand extends SimpleCommand 
	{ 
		//public static const NAME : String = 'OBTENIR_LISTE_ENSEIGNEMENTS_ETUDE_COMMAND';
		 
		/** 
		 * Constructor 
		 */ 
		public function ObtenirListeEnseignantsEtudeCommand() 
		{ 
			super(); 
		} 
		
		/** 
		 * Initialize all commands/controllers of the application 
		 */
		override public function execute(note : INotification) : void 
		{  
			var anneeEtudeProxy:AnneeEtudeProxy = facade.retrieveProxy(AnneeEtudeProxy.NAME) as AnneeEtudeProxy; 
			var anneeUniversitaire:AnneeUniversitaire = (note.getBody() as Array)[0] as AnneeUniversitaire;
			var formation:Formation = (note.getBody() as Array)[1] as Formation;
			anneeEtudeProxy.obtenirListeEnseignants(anneeUniversitaire,formation); 
		} 
	}
}